package org.goldonframework.platform.util;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;

import org.apache.log4j.Logger;

public class StringHelper {
	private static Logger logger = LoggerFactory.getLogger(StringHelper.class.getName());

	public static Date stringConvertDate(String str) {
		SimpleDateFormat format = new SimpleDateFormat("YYYY-MM-DD");
		Date date = null;
		try {
			date = format.parse(str);
		} catch (ParseException e) {
			logger.error("String Parse to Date error" + e);
		}
		return date;
	}
}
